#include <iostream>

// 声明各个特性的演示函数
void demonstrate_structured_bindings();
void demonstrate_if_constexpr();
void demonstrate_inline_variables();
void demonstrate_fold_expressions();
void demonstrate_filesystem();
void demonstrate_optional();
void demonstrate_variant();
void demonstrate_any();
void demonstrate_string_view();
void demonstrate_invoke();
void demonstrate_if_switch_init();
void demonstrate_byte();
void demonstrate_apply();
void demonstrate_parallel_algorithms();

namespace cpp17 {

void demonstrate_features() {
    std::cout << "1. 结构化绑定:\n";
    demonstrate_structured_bindings();
    std::cout << "\n";

    std::cout << "2. 编译期if (if constexpr):\n";
    demonstrate_if_constexpr();
    std::cout << "\n";

    std::cout << "3. 内联变量:\n";
    demonstrate_inline_variables();
    std::cout << "\n";

    std::cout << "4. 折叠表达式:\n";
    demonstrate_fold_expressions();
    std::cout << "\n";

    std::cout << "5. 文件系统库:\n";
    demonstrate_filesystem();
    std::cout << "\n";

    std::cout << "6. std::optional:\n";
    demonstrate_optional();
    std::cout << "\n";

    std::cout << "7. std::variant:\n";
    demonstrate_variant();
    std::cout << "\n";

    std::cout << "8. std::any:\n";
    demonstrate_any();
    std::cout << "\n";

    std::cout << "9. std::string_view:\n";
    demonstrate_string_view();
    std::cout << "\n";
    
    std::cout << "10. std::invoke:\n";
    demonstrate_invoke();
    std::cout << "\n";

    std::cout << "11. if/switch 初始化器:\n";
    demonstrate_if_switch_init();
    std::cout << "\n";

    std::cout << "12. std::byte:\n";
    demonstrate_byte();
    std::cout << "\n";

    std::cout << "13. std::apply:\n";
    demonstrate_apply();
    std::cout << "\n";

    std::cout << "14. 并行算法:\n";
    demonstrate_parallel_algorithms();
    std::cout << "\n";
}

} // namespace cpp17

